// 智能办公主题样式
// 主色调 - 科技蓝
$office-primary: #1890ff;
$office-primary-light: #40a9ff;
$office-primary-dark: #096dd9;

// 辅助色 - 智能绿
$office-success: #52c41a;
$office-success-light: #73d13d;
$office-success-dark: #389e0d;

// 警告色 - 活力橙
$office-warning: #fa8c16;
$office-warning-light: #ffa940;
$office-warning-dark: #d46b08;

// 错误色 - 科技红
$office-error: #f5222d;
$office-error-light: #ff4d4f;
$office-error-dark: #cf1322;

// 中性色
$office-text-primary: #262626;
$office-text-secondary: #595959;
$office-text-disabled: #bfbfbf;
$office-border: #d9d9d9;
$office-background: #fafafa;

// 智能办公侧边栏样式
.office-sidebar {
  background: linear-gradient(180deg, #ffffff 0%, #f8f9fa 100%);
  border-right: 1px solid rgba(24, 144, 255, 0.1);
  box-shadow: 2px 0 8px rgba(0, 0, 0, 0.06);
  
  .el-menu {
    background: transparent;
    border: none;
    
    .el-menu-item, .el-submenu__title {
      height: 56px;
      line-height: 56px;
      margin: 4px 12px;
      border-radius: 12px;
      transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
      position: relative;
      overflow: hidden;
      
      &:hover {
        background: linear-gradient(135deg, rgba(24, 144, 255, 0.08) 0%, rgba(24, 144, 255, 0.04) 100%);
        color: $office-primary;
        transform: translateX(4px);
        
        .svg-icon {
          transform: scale(1.1);
          color: $office-primary;
        }
      }
      
      &.is-active {
        background: linear-gradient(135deg, $office-primary 0%, $office-primary-light 100%);
        color: #ffffff;
        box-shadow: 0 4px 12px rgba(24, 144, 255, 0.3);
        
        .svg-icon {
          color: #ffffff;
        }
        
        &::before {
          content: '';
          position: absolute;
          left: 0;
          top: 0;
          bottom: 0;
          width: 4px;
          background: linear-gradient(180deg, $office-success 0%, $office-warning 100%);
          border-radius: 0 2px 2px 0;
        }
      }
      
      .svg-icon {
        margin-right: 12px;
        font-size: 18px;
        transition: all 0.3s ease;
        color: $office-text-secondary;
      }
    }
    
    .el-submenu {
      .el-menu-item {
        margin-left: 24px;
        height: 48px;
        line-height: 48px;
        border-radius: 8px;
        
        &:hover {
          background: rgba(24, 144, 255, 0.06);
          color: $office-primary;
        }
        
        &.is-active {
          background: rgba(24, 144, 255, 0.1);
          color: $office-primary;
          font-weight: 500;
        }
      }
    }
  }
}

// 智能办公顶部导航栏样式
.office-navbar {
  background: linear-gradient(135deg, #ffffff 0%, #f8f9fa 100%);
  border-bottom: 1px solid rgba(24, 144, 255, 0.1);
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.06);
  backdrop-filter: blur(10px);
  
  .navbar-container {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 24px;
    height: 64px;
    
    .navbar-left {
      display: flex;
      align-items: center;
      gap: 16px;
      
      .hamburger-container {
        width: 48px;
        height: 48px;
        border-radius: 12px;
        display: flex;
        align-items: center;
        justify-content: center;
        cursor: pointer;
        transition: all 0.3s ease;
        background: rgba(255, 255, 255, 0.8);
        border: 1px solid rgba(24, 144, 255, 0.1);
        padding: 0;
        
        &:hover {
          background: rgba(24, 144, 255, 0.12);
          transform: scale(1.05);
          box-shadow: 0 4px 12px rgba(24, 144, 255, 0.2);
        }
        
        .hamburger {
          width: 36px;
          height: 36px;
          color: $office-text-secondary;
          fill: currentColor;
        }
      }
      
      .breadcrumb-container {
        .el-breadcrumb {
          .el-breadcrumb__item {
            .el-breadcrumb__inner {
              color: $office-text-secondary;
              font-weight: 500;
              
              &:hover {
                color: $office-primary;
              }
            }
            
            &:last-child {
              .el-breadcrumb__inner {
                color: $office-text-primary;
                font-weight: 600;
              }
            }
          }
        }
      }
    }
    
    .navbar-right {
      display: flex;
      align-items: center;
      gap: 16px;
      
      .right-menu-item {
        width: 44px;
        height: 44px;
        border-radius: 10px;
        display: flex;
        align-items: center;
        justify-content: center;
        cursor: pointer;
        transition: all 0.3s ease;
        position: relative;
        background: rgba(255, 255, 255, 0.8);
        border: 1px solid rgba(24, 144, 255, 0.1);
        
        &:hover {
          background: rgba(24, 144, 255, 0.12);
          transform: translateY(-2px);
          box-shadow: 0 4px 12px rgba(24, 144, 255, 0.2);
          
          .svg-icon {
            color: $office-primary;
          }
        }
        
        .svg-icon {
          font-size: 18px;
          color: $office-text-secondary;
          transition: all 0.3s ease;
        }
        
        &.avatar-container {
          width: auto;
          min-width: 44px;
          height: 44px;
          padding: 0 8px;
          
          .avatar-wrapper {
            display: flex;
            align-items: center;
            gap: 8px;
            width: 100%;
            height: 100%;
            
            .user-avatar {
              width: 36px;
              height: 36px;
              border-radius: 50%;
              border: 2px solid rgba(24, 144, 255, 0.2);
              transition: all 0.3s ease;
              object-fit: cover;
              display: block;
              
              &:hover {
                border-color: $office-primary;
                transform: scale(1.05);
              }
            }
            
            .el-icon-caret-bottom {
              color: $office-text-secondary;
              transition: all 0.3s ease;
              font-size: 12px;
            }
          }
          
          &:hover {
            background: rgba(24, 144, 255, 0.12);
            transform: translateY(-2px);
            box-shadow: 0 4px 12px rgba(24, 144, 255, 0.2);
          }
        }
      }
    }
  }
}

// 智能办公顶部菜单样式
.office-topmenu {
  .el-menu--horizontal {
    background: transparent;
    border: none;
    
    .el-menu-item, .el-submenu__title {
      height: 64px;
      line-height: 64px;
      padding: 0 20px;
      margin: 0 4px;
      border-radius: 12px;
      transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
      position: relative;
      overflow: hidden;
      
      &:hover {
        background: linear-gradient(135deg, rgba(24, 144, 255, 0.08) 0%, rgba(24, 144, 255, 0.04) 100%);
        color: $office-primary;
        transform: translateY(-2px);
        
        .svg-icon {
          transform: scale(1.1);
          color: $office-primary;
        }
      }
      
      &.is-active {
        background: linear-gradient(135deg, $office-primary 0%, $office-primary-light 100%);
        color: #ffffff;
        box-shadow: 0 4px 12px rgba(24, 144, 255, 0.3);
        
        .svg-icon {
          color: #ffffff;
        }
        
        &::after {
          content: '';
          position: absolute;
          bottom: 0;
          left: 50%;
          transform: translateX(-50%);
          width: 24px;
          height: 3px;
          background: linear-gradient(90deg, $office-success 0%, $office-warning 100%);
          border-radius: 2px;
        }
      }
      
      .svg-icon {
        margin-right: 8px;
        font-size: 16px;
        transition: all 0.3s ease;
        color: $office-text-secondary;
      }
    }
  }
}

// 智能办公Logo样式
.office-logo {
  .sidebar-logo-container {
    background: linear-gradient(135deg, $office-primary 0%, $office-primary-light 100%);
    position: relative;
    overflow: hidden;
    
    &::before {
      content: '';
      position: absolute;
      top: 0;
      left: 0;
      right: 0;
      bottom: 0;
      background: linear-gradient(45deg, transparent 30%, rgba(255, 255, 255, 0.1) 50%, transparent 70%);
      animation: shimmer 3s infinite;
    }
    
    .sidebar-logo-link {
      position: relative;
      z-index: 1;
      
      .sidebar-logo {
        width: 36px;
        height: 36px;
        border-radius: 8px;
        box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
      }
      
      .sidebar-title {
        color: #ffffff;
        font-weight: 600;
        font-size: 16px;
        text-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
      }
    }
  }
}

// 动画效果
@keyframes shimmer {
  0% {
    transform: translateX(-100%);
  }
  100% {
    transform: translateX(100%);
  }
}

// 智能办公卡片样式
.office-card {
  background: #ffffff;
  border-radius: 16px;
  border: 1px solid rgba(24, 144, 255, 0.1);
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
  transition: all 0.3s ease;
  
  &:hover {
    transform: translateY(-4px);
    box-shadow: 0 8px 32px rgba(24, 144, 255, 0.15);
  }
  
  .el-card__header {
    background: linear-gradient(135deg, rgba(24, 144, 255, 0.02) 0%, rgba(24, 144, 255, 0.05) 100%);
    border-bottom: 1px solid rgba(24, 144, 255, 0.1);
    border-radius: 16px 16px 0 0;
    padding: 20px 24px;
    
    .card-header {
      display: flex;
      align-items: center;
      gap: 12px;
      
      .header-title {
        font-size: 18px;
        font-weight: 600;
        color: $office-text-primary;
        
        &::before {
          content: '';
          display: inline-block;
          width: 4px;
          height: 18px;
          background: linear-gradient(180deg, $office-primary 0%, $office-success 100%);
          border-radius: 2px;
          margin-right: 12px;
          vertical-align: middle;
        }
      }
    }
  }
  
  .el-card__body {
    padding: 24px;
  }
}

// 智能办公按钮样式
.office-button {
  &.el-button--primary {
    background: linear-gradient(135deg, $office-primary 0%, $office-primary-light 100%);
    border: none;
    border-radius: 8px;
    padding: 12px 24px;
    font-weight: 500;
    transition: all 0.3s ease;
    
    &:hover {
      transform: translateY(-2px);
      box-shadow: 0 6px 20px rgba(24, 144, 255, 0.3);
    }
    
    &:active {
      transform: translateY(0);
    }
  }
  
  &.el-button--success {
    background: linear-gradient(135deg, $office-success 0%, $office-success-light 100%);
    border: none;
    border-radius: 8px;
    padding: 12px 24px;
    font-weight: 500;
    transition: all 0.3s ease;
    
    &:hover {
      transform: translateY(-2px);
      box-shadow: 0 6px 20px rgba(82, 196, 26, 0.3);
    }
  }
  
  &.el-button--warning {
    background: linear-gradient(135deg, $office-warning 0%, $office-warning-light 100%);
    border: none;
    border-radius: 8px;
    padding: 12px 24px;
    font-weight: 500;
    transition: all 0.3s ease;
    
    &:hover {
      transform: translateY(-2px);
      box-shadow: 0 6px 20px rgba(250, 140, 22, 0.3);
    }
  }
}

// 智能办公表格样式
.office-table {
  .el-table {
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
    
    .el-table__header {
      background: linear-gradient(135deg, rgba(24, 144, 255, 0.05) 0%, rgba(24, 144, 255, 0.02) 100%);
      
      th {
        background: transparent;
        color: $office-text-primary;
        font-weight: 600;
        border-bottom: 2px solid rgba(24, 144, 255, 0.1);
      }
    }
    
    .el-table__body {
      tr {
        transition: all 0.3s ease;
        
        &:hover {
          background: rgba(24, 144, 255, 0.02);
          transform: scale(1.01);
        }
        
        td {
          border-bottom: 1px solid rgba(24, 144, 255, 0.05);
        }
      }
    }
  }
}

// 智能办公表单样式
.office-form {
  .el-form-item {
    .el-form-item__label {
      color: $office-text-primary;
      font-weight: 500;
    }
    
    .el-input__inner {
      border-radius: 8px;
      border: 1px solid rgba(24, 144, 255, 0.2);
      transition: all 0.3s ease;
      
      &:focus {
        border-color: $office-primary;
        box-shadow: 0 0 0 2px rgba(24, 144, 255, 0.1);
      }
    }
  }
}

// 响应式设计
@media (max-width: 768px) {
  .office-sidebar {
    .el-menu {
      .el-menu-item, .el-submenu__title {
        margin: 2px 8px;
        height: 48px;
        line-height: 48px;
      }
    }
  }
  
  .office-navbar {
    .navbar-container {
      padding: 0 16px;
      height: 56px;
    }
  }
}

// 深色主题支持
.office-theme-dark {
  .office-sidebar {
    background: linear-gradient(180deg, #1f1f1f 0%, #141414 100%);
    border-right: 1px solid rgba(255, 255, 255, 0.1);
    
    .el-menu {
      .el-menu-item, .el-submenu__title {
        color: rgba(255, 255, 255, 0.85);
        
        &:hover {
          background: rgba(24, 144, 255, 0.15);
          color: #ffffff;
        }
        
        .svg-icon {
          color: rgba(255, 255, 255, 0.65);
        }
      }
    }
  }
  
  .office-navbar {
    background: linear-gradient(135deg, #1f1f1f 0%, #141414 100%);
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
  }
} 